<script src="//netdna.bootstrapcdn.com/bootstrap/3.0.2/js/bootstrap.min.js"></script>
<script src="/js/site.js?1"></script>

<script src="//cdnjs.cloudflare.com/ajax/libs/Cookies.js/0.4.0/cookies.min.js"></script>

<script>

  $('.navbar .dropdown').on('show.bs.dropdown', function(e){
    //$(this).find('.dropdown-menu').addClass('animated fadeInDown');
  });

  // ADD SLIDEUP ANIMATION TO DROPDOWN //
  $('.navbar .dropdown').on('hide.bs.dropdown', function(e){
    //$(this).find('.dropdown-menu').first().stop(true, true).slideUp(200);
    //$(this).find('.dropdown-menu').removeClass('animated fadeInDown');
  });


try {
  var d = new Date('{{site.posts.first.date}}');
  var ts = d.getTime();

  var cd = Cookies.get('_iondj');
  if(cd) {
    cd = JSON.parse(atob(cd));
    if(parseInt(cd.lp) < ts) {
      var bt = document.getElementById('blog-badge');
      bt.style.display = 'block';
    }

    cd.lp = ts;
  } else {
    var bt = document.getElementById('blog-badge');
    bt.style.display = 'block';
    cd = {
      lp: ts
    }
  }

  Cookies.set('_iondj', btoa(JSON.stringify(cd)));
} catch(e) {
}
</script>

<div id="fb-root"></div>
<script>(function(d, s, id) {
  var js, fjs = d.getElementsByTagName(s)[0];
  if (d.getElementById(id)) return;
  js = d.createElement(s); js.id = id;
  js.src = "//connect.facebook.net/en_US/all.js#xfbml=1";
  fjs.parentNode.insertBefore(js, fjs);
}(document, 'script', 'facebook-jssdk'));</script>
